<%
    Function return_RFC822_Date(myDate, offset)
      Dim myDay, myDays, myMonth, myYear
      Dim myHours, myMonths, mySeconds

      myDate = CDate(myDate)
      myDay = WeekdayName(Weekday(myDate),true)
      myDays = Day(myDate)
      myMonth = MonthName(Month(myDate), true)
      myYear = Year(myDate)
      myHours = zeroPad(Hour(myDate), 2)
      myMinutes = zeroPad(Minute(myDate), 2)
      mySeconds = zeroPad(Second(myDate), 2)

      return_RFC822_Date = myDay&", "& _
                           myDays&" "& _
                           myMonth&" "& _
                           myYear&" "& _
                           myHours&":"& _
                           myMinutes&":"& _
                           mySeconds&" "& _
                           offset
    End Function

    Function zeroPad(m, t)
      zeroPad = String(t-Len(m),"0")&m
    End Function

    Function cSubString(str, code)
        If (len(str) > 300) Then
            cSubString = left(str, 300)
            'cSubString = replace(cSubString, vbcrlf & vbcrlf, "<br />")
            'cSubString = replace(cSubString, vbcrlf, "<br />")
            cSubString = cSubString & " <a title='Read Full Details' style='text-decoration:none;' href='Candidates_JobDetails.asp?jobID=" & code & "'>...</a>"
        Else
            cSubString = str
        End If
        'cSubString = str
    End Function
%>